package com.manage.project.biz.service.impl;

import java.util.List;
import com.manage.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.manage.project.biz.mapper.BizJidiansheshiyingjijianxiuMapper;
import com.manage.project.biz.domain.BizJidiansheshiyingjijianxiu;
import com.manage.project.biz.service.IBizJidiansheshiyingjijianxiuService;

/**
 Service业务层处理
 *
 * @author liutao
 *
 */
@Service
public class BizJidiansheshiyingjijianxiuServiceImpl implements IBizJidiansheshiyingjijianxiuService
{
    @Autowired
    private BizJidiansheshiyingjijianxiuMapper bizJidiansheshiyingjijianxiuMapper;

    /**
     * 查询机电设施应急检修
     *
     * @param id 机电设施应急检修主键
     * @return 机电设施应急检修
     */
    @Override
    public BizJidiansheshiyingjijianxiu selectBizJidiansheshiyingjijianxiuById(Long id)
    {
        return bizJidiansheshiyingjijianxiuMapper.selectBizJidiansheshiyingjijianxiuById(id);
    }

    @Override
    public BizJidiansheshiyingjijianxiu selectBizJidiansheshiyingjijianxiuByshebeiId(String id) {
        return bizJidiansheshiyingjijianxiuMapper.selectBizJidiansheshiyingjijianxiuByshebeiId(id);
    }

    /**
     * 查询机电设施应急检修列表
     *
     * @param bizJidiansheshiyingjijianxiu 机电设施应急检修
     * @return 机电设施应急检修
     */
    @Override
    public List<BizJidiansheshiyingjijianxiu> selectBizJidiansheshiyingjijianxiuList(BizJidiansheshiyingjijianxiu bizJidiansheshiyingjijianxiu)
    {
        return bizJidiansheshiyingjijianxiuMapper.selectBizJidiansheshiyingjijianxiuList(bizJidiansheshiyingjijianxiu);
    }

    /**
     * 新增机电设施应急检修
     *
     * @param bizJidiansheshiyingjijianxiu 机电设施应急检修
     * @return 结果
     */
    @Override
    public int insertBizJidiansheshiyingjijianxiu(BizJidiansheshiyingjijianxiu bizJidiansheshiyingjijianxiu)
    {
        bizJidiansheshiyingjijianxiu.setCreateTime(DateUtils.getNowDate());
        return bizJidiansheshiyingjijianxiuMapper.insertBizJidiansheshiyingjijianxiu(bizJidiansheshiyingjijianxiu);
    }

    /**
     * 修改机电设施应急检修
     *
     * @param bizJidiansheshiyingjijianxiu 机电设施应急检修
     * @return 结果
     */
    @Override
    public int updateBizJidiansheshiyingjijianxiu(BizJidiansheshiyingjijianxiu bizJidiansheshiyingjijianxiu)
    {
        bizJidiansheshiyingjijianxiu.setUpdateTime(DateUtils.getNowDate());
        return bizJidiansheshiyingjijianxiuMapper.updateBizJidiansheshiyingjijianxiu(bizJidiansheshiyingjijianxiu);
    }

    /**
     * 批量删除机电设施应急检修
     *
     * @param ids 需要删除的机电设施应急检修主键
     * @return 结果
     */
    @Override
    public int deleteBizJidiansheshiyingjijianxiuByIds(Long[] ids)
    {
        return bizJidiansheshiyingjijianxiuMapper.deleteBizJidiansheshiyingjijianxiuByIds(ids);
    }

    /**
     * 删除机电设施应急检修信息
     *
     * @param id 机电设施应急检修主键
     * @return 结果
     */
    @Override
    public int deleteBizJidiansheshiyingjijianxiuById(Long id)
    {
        return bizJidiansheshiyingjijianxiuMapper.deleteBizJidiansheshiyingjijianxiuById(id);
    }
}
